
const state = {
  pictureList: [],
  landDetail: {},
  missionDetail: {}
}
const mutations = {
  setValue (state, payload) {
    state.pictureList = payload
  },
  removeValue (state) {
    state.pictureList = []
  },
  setLandDetail (state, payload) {
    state.landDetail = payload
  },
  removeLandDetail (state) {
    state.landDetail = {}
  },
  setmissionDetail (state, payload) {
    state.missionDetail = payload
  },
  removemissionDetail (state) {
    state.missionDetail = {}
  }
}
const actions = {
  // 图片list
  updateValue (context, payload) {
    context.commit('setValue', payload)
  },
  removePictureList ({ commit }) {
    commit('removeValue')
  },
  // 地块详情
  updateLandDetail (context, payload) {
    context.commit('setLandDetail', payload)
  },
  removeLandDetail ({ commit }) {
    commit('removeLandDetail')
  },
  // 地块任务详情
  updatemissionDetail (context, payload) {
    context.commit('setmissionDetail', payload)
  },
  removemissionDetail ({ commit }) {
    commit('removemissionDetail')
  }
}
export default {
  namespaced: true,
  state,
  mutations,
  actions
}
